import unittest
from ddt import ddt, data, unpack
import csvv


# 数据[['user1', '123'], ['user2', '124'], ['user3', '125']]
@ddt
class MyTestCase(unittest.TestCase):
    @data(*(csvv.read_csv("testdata.csv")))   # 第一次解包去掉外层列表[]
    @unpack    # 第二次解包返回具体值
    def test_1(self, a, b):
        print(a)
        print(b)


if __name__ == '__main__':
    unittest.main()
